1. Field of the Invention
Apparatuses and methods consistent with the present invention relate to video coding, and more particularly, to determining coding for coefficients of a residual block, an encoder and a decoder.
2. Description of the Related Art
The main objective in compressing video data is to reduce the number of bits required for showing sequences of video images while maintaining an acceptable level of image quality when an encoded bitstream is reproduced. In particular, in video data compression, if video data in one frame is converted to the frequency domain, much energy is focused on a low-frequency signal. Accordingly, data is focused on a low-frequency component by dividing one frame into a plurality of macroblocks and performing 4×4 or 8×8 discrete cosine transformation (DCT) on each of the macroblocks, thereby greatly increasing compression efficiency.
DCT is a method of frequency conversion and is used to reduce spatial redundancy of pixels. DCT is widely used due to its superior performance compared to other conversion methods with respect to energy density. In video coding, 4×4 DCT and 8×8 DCT are used. A DCT converted image is decoded by performing inverse discrete cosine transformation IDCT.
When DCT is performed, DCT coefficients of a 4×4 block or DCT coefficients of an 8×8 block are obtained. The top left coefficient of the 4×4 block or the 8×8 block is a direct current (DC) coefficient and the others are alternating current (AC) coefficients. In particular, the DC coefficient is an average value of the DCT coefficients and a general shape of the block can be predicted by using the DC coefficient. When the AC coefficients of the prediction block have non-zero values at a predetermined frequency, the effect of a residual block at a corresponding frequency can be ignored.
Currently, a skip macroblock mode is used as a method of reducing the number of bits. The skip macroblock mode reduces the number of bits to be transferred to a decoder by not coding part of a macroblock. However, the conventional skip macroblock mode does not transfer all information regarding a residual block of the corresponding macroblock to the decoder. Also, a method of skipping some coefficients of the residual block is not disclosed.